﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class Modeling_Sub_Pages_NewsPage : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {
        try
        {
            int id = Convert.ToInt32(Request.QueryString["id"].ToString());

            if (id == 0)
            {
                Label1.Text = "You are login!";
                Label1.ForeColor = System.Drawing.Color.Red;
            }
            else if (id == 1)
            {
                Label1.Text = "You don't have permission to access this page!";
                Label1.ForeColor = System.Drawing.Color.Red;
            }
            else if (id == 2)
            {
                Label1.Text = "This course is end regis!";
                Label1.ForeColor = System.Drawing.Color.Red;
            }
            else if (id == 3)
            {
                Label1.Text = "You have registered on this course!";
                Label1.ForeColor = System.Drawing.Color.Red;
            }
            else if (id == 4)
            {
                Label1.Text = "Successful change password!";
                Label1.ForeColor = System.Drawing.Color.Green;
            }
            else if (id == 5)
            {
                Label1.Text = "Successful send feedback!";
                Label1.ForeColor = System.Drawing.Color.Green;
            }
            else {
                Response.Redirect("~/ErrorPage.aspx");
            }
        }
        catch (Exception)
        {
            Response.Redirect("~/ErrorPage.aspx");
        }
    }
}